package ch8.zadanie;

import java.text.SimpleDateFormat;

public class Spis {

	public static void main(String[] args) throws Exception {

		SimpleDateFormat data2 = new SimpleDateFormat("dd/MM/yyyy");
		Person[] persons = new Person[args.length / 5];
		for (Integer idx = 0; idx < persons.length; idx++) {
			persons[idx] = new Person(args[idx * 5 + 0], args[idx * 5 + 1],
					data2.parse(args[idx * 5 + 2]), args[idx * 5 + 3],
					data2.parse(args[idx * 5 + 4]));
			System.out.println(persons[idx].introduceYou());
		}

	}

}
